<!-- 考试 -->
<template>
  <div class="fix_scroll">
    <div class="exam_detail_page">
      <div class="cover_wrapper top_wrapper">
        <img :src="productInfo.image | renderImg(750,400)" alt="">
      </div>
      <div class="intro_wrap">
        <div class="intro">
          <div class="title">
            {{productInfo.name}}
          </div>
          <div class="start_time">
            <i class="iconfont icon-clock1"></i>
            <span>{{productInfo.start_time*1000 | dateFormat}}</span>-
            <span>{{productInfo.end_time*1000 | dateFormat}}</span>
          </div>
        </div>
      </div>
      <div class="detail_item">
        <div class="items">
          <div class="item_title">
             80
          </div>
          <div class="item_des">
             考试时间
          </div>
        </div>
        <div class="items">
          <div class="item_title">
             80
          </div>
          <div class="item_des">
             考试时间
          </div>
        </div>
        <div class="items">
          <div class="item_title">
             80
          </div>
          <div class="item_des">
             考试时间
          </div>
        </div>
      </div>
       <div class="accordion_list">
        <div class="item open">
          <div class="i_header">
            <div class="icon">
              <i class="iconfont icon-icon-files"></i>
            </div>
            <div class="title">
              考试说明
            </div>
          </div>
          <div class="i_content">
              <div class="des_wrapper">
                <div v-html="productInfo.description" class="des_content">
                </div>
              </div>
          </div>
        </div>
      </div>
      <div class="com_buy_box">
        <div class="buy_btn_wrapper">
          <a @click="createOrder()" class="a_btn_buy" href="javascript:void(0);">开始考试</a>
        </div>
      </div>
    </div>
  </div>
</template>
<script>
import Vue from "vue";

export default {
  name: "exam_detail",
  components: {},
  data() {
    return {
      //resource_id: this.$route.params.id,
      resource_id: "926828697e3e90db6d494494bc79ee43066ae562",
      productInfo: {
        info: "",
        price: 0
      }
      //分享人id
    };
  },
  computed: {},
  mounted: function() {
    this.$nextTick(function() {
      this.getProductInfo();
    });
  },
  methods: {
    getProductInfo: function() {
      let params = {
        functioncode: "common_exam_info",
        exam_id: this.resource_id,
        team_id: this.from_team_id != "" ? this.from_team_id : this.team_id
      };
      this.api.get(params).then(data => {
        if (data.returncode == "000000" && data.record) {
          this.productInfo = data.record;
        }
      });
    }
  }
};
</script>

<style lang="less" scoped>

</style>
